<%@ include file="../include/import.jsp" %>
<!DOCTYPE html>
<html lang="en">
<head>
<jsp:include page="../include/htmlhead.jsp"/>
</head>
<body>
<jsp:include page="../include/headbody.jsp"/>
<jsp:include page="../home/leftnav.jsp"/>
<div id="content">
	<div id="content-header">
		<h1>Contact/Event View</h1>
		<%--
		<div class="btn-group">
			<button class="btn"><i class="icon-eye-open"></i> View</button>
		</div> --%>
	</div>
	<div id="breadcrumb">
		<a href="main.sw" title="Go to Home" class="tip-bottom"><i class="icon-home"></i>Home</a>
		<a href="list.sw">Contact/Event</a>
		<a href="#" class="current">View</a>
	</div>
	<div class="container-fluid">
		<div class="row-fluid">
			<div class="span12">
				<div class="widget-box">
					<div class="widget-title">
						<span class="icon"><i class="icon-th"></i></span>
						<h5>Contact/Event View</h5>
					</div>
					<div class="widget-content nopadding">
						<form action="#" class="form-horizontal">
						<div class="control-group">
							<label class="control-label">External Id</label>
							<div class="controls">
								<c:out value="${eventContactObj.extId}"/>
							</div>
						</div>
						<div class="control-group">
							<label class="control-label">Type</label>
							<div class="controls">
								<c:out value="${eventContactObj.type eq 1?'Contact':'Event'}"/>
							</div>
						</div>
						<div class="control-group">
							<label class="control-label">Name</label>
							<div class="controls">
								<c:out value="${eventContactObj.name}"/>
							</div>
						</div>
						<div class="control-group">
							<label class="control-label">Status</label>
							<div class="controls">
								<c:out value="${eventContactObj.active?'Active':'Disabled'}"/>
							</div>
						</div>
						<div class="control-group">
							<label class="control-label">Contact Email</label>
							<div class="controls">
								<c:out value="${eventContactObj.contactEmail}"/>
							</div>
						</div>
						<div class="control-group">
							<label class="control-label">Internal Email</label>
							<div class="controls">
								<c:out value="${eventContactObj.internalEmail}"/>
							</div>
						</div>
						<div class="control-group">
							<label class="control-label">Activate Start Date</label>
							<div class="controls">
								<i class="icon-calendar"></i>
								<fmt:formatDate type="both" value="${eventContactObj.activateStartDate}"/>
							</div>
						</div>
						<div class="control-group">
							<label class="control-label">Activate End Date</label>
							<div class="controls">
								<i class="icon-calendar"></i>
								<fmt:formatDate type="both" value="${eventContactObj.activateEndDate}"/>
							</div>
						</div>
						<div class="control-group">
							<label class="control-label">Created Date</label>
							<div class="controls">
								<i class="icon-calendar"></i>
								<fmt:formatDate type="both" value="${eventContactObj.createdDate}"/>
							</div>
						</div>
						<div class="control-group">
							<label class="control-label">Last Updated Date</label>
							<div class="controls">
								<i class="icon-calendar"></i>
								<fmt:formatDate type="both" value="${eventContactObj.updatedDate}"/>
							</div>
						</div>
						</form>
					</div>
				</div>
				<div class="widget-box">
					<div class="widget-title">
						<span class="icon"><i class="icon-th"></i></span>
						<h5>Wifi Account List</h5>
					</div>
					<div class="widget-content nopadding">
					<table class="table table-bordered table-striped table-hover">
						<thead>
							<tr>
								<th>Username</th>
								<th>Package Type</th>
								<th>Max Device</th>
							</tr>
						</thead>
						<tbody>
							<c:forEach items="${eventContactObj.wifiAccoutList}" var="wa" varStatus="waStatus">
							<tr>
								<td><c:out value="${wa.wifiUsername}"/></td>
								<td><c:out value="${tss:packageType(wa.packageType)}"/></td>
								<td><c:out value="${wa.maxDevices}"/></td>
							</tr>
							</c:forEach>
						</tbody>
					</table>
					</div>
				</div>
			</div>
		</div>
		<jsp:include page="../include/copyright.jsp"/>
	</div>
</div>
<script type="text/javascript">
	$(document).ready(function(){
				 
		<c:if test="${not empty errmsg}"> 
		$.gritter.add({
			// (string | mandatory) the heading of the notification
			title: 'Centient Notification',
			// (string | mandatory) the text inside the notification
			text: '${errmsg}'
		});
		</c:if>
		
	});
</script>
<jsp:include page="../include/footerscript.jsp"/>
</body>
</html>	